<HTML>
<!--
 -  
 -  This file is part of the OpenLink Software Virtuoso Open-Source (VOS)
 -  project.
 -  
 -  Copyright (C) 1998-2025 OpenLink Software
 -  
 -  This project is free software; you can redistribute it and/or modify it
 -  under the terms of the GNU General Public License as published by the
 -  Free Software Foundation; only version 2 of the License, dated June 1991.
 -  
 -  This program is distributed in the hope that it will be useful, but
 -  WITHOUT ANY WARRANTY; without even the implied warranty of
 -  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 -  General Public License for more details.
 -  
 -  You should have received a copy of the GNU General Public License along
 -  with this program; if not, write to the Free Software Foundation, Inc.,
 -  51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
 -  
 -  
-->
<HEAD>
<TITLE>OpenLink Virtuoso JDBC Scrollable Cursor Demonstration</TITLE>
</HEAD>
<BODY LINK="#0000ff" VLINK="#800080">

<H1>OpenLink Virtuoso JDBC Scrollable Cursor Applet Demonstration</H1>
<P><HR></P>
<P>&nbsp;This is a demonstration of an applet using the OpenLink Virtuoso JDBC Driver with the JDBC Scrollable Cursor specification. </P>
<H2>Starting</H2>
<P>When the Web browser has finished loading the Java applet, a window containing the JDBC applet will appear:</P>
<P><IMG SRC="WebScrollDemo21.gif" WIDTH=608 HEIGHT=371></P>
<P>&nbsp;</P>
<H2>Running a Query</H2>
<P>When it is running, click on the "Query" button to execute a SQL query against the default connection URL. If successful, you should see the first row of the resultset filling the applet window:</P>
<P><IMG SRC="WebScrollDemo22.gif" WIDTH=608 HEIGHT=371></P>
<P>Click on the "Next" button to retrieve the next row, "Previous" to go back a row, "First" to move directly to the first row, and "Last" to move to the last row. </P>
<P>Clicking "Delete" will attempt to delete the row from the database. Clicking on "Refresh" will now retrieve the latest values from the database to refresh the row. However this may or may not be successful dependent on the restrictions place on the resultset by the underlying database. </P>
<P>"Insert" will attempt to add the contents of the current row as a new row to the relevant tables forming the resultset. "Update" will attempt to update the modified contents of current row to the database. Again, the success of these two operations depends on the restrictions placed on the underlying database.</P>
<P>To move to a particular absolute position in the resultset, enter that position into the edit box, and press the "Absolute" button. You may move a relative number of rows from the current position by entering the offset as a positive or negative number, then press "Relative" button.</P>
<H2>Changing the connection URL</H2>
<P>To change the connection URL, select "File|Set Connection URL.." from the menu. A dialog box will appear enabling you to change JDBC driver used, and the connection URL:</P>
<P><IMG SRC="WebScrollDemo23.gif" WIDTH=350 HEIGHT=216></P>
<P>Please note that due to the applet security restrictions, it is only possible to connect to the same server IP as the Web server.</P>
<P><HR></P>
<P><A HREF="WebScrollDemo2.java"><I>The Java source for this applet</I></A> </P>
<P>&nbsp;<applet code=WebScrollDemo2.class archive=../virtjdbc2.jar id=WebScrollDemo2 height=1 width=1>
  <PARAM name=URL1 value=":1112/UID=demo/PWD=demo/">
  <PARAM name="numParams" value="1">
</applet></P>
</BODY>
</HTML>
